package com.longge;

public class RotateString {

    public boolean rotateString(String s, String goal) {

        int n  =  s.length();
        while(n!=0)
        {
            n--;
            s = s.substring(1)+ s.charAt(0);
            if(s.equals(goal)) return true;
        }
        return false;
    }
}
